The penis becomes erect due to the erectile tissue around the urethra becoming filled with blood, this happens because of sexual stimulation.